package com.starview.star.operators.string;

import com.starview.platform.data.type.Refresher;
import com.starview.platform.data.type.StandardTypes;
import com.starview.platform.data.type.TypeUtils;
import com.starview.star.operators.Builtin;
import com.starview.star.operators.Intrinsics;
import com.starview.star.operators.string.runtime.Regexp;



/**
 * The regexp builtin pattern is used to implement pattern matching against
 * lists
 * 
 * @author fgm
 * 
 */

public class RegexpOps
{
  public static final String name = "__regexpMatch";

  public static void declare(Intrinsics cxt)
  {
    cxt.declareBuiltin(new Builtin(name, Refresher.generalize(TypeUtils.patternType(TypeUtils.tupleType(),
        StandardTypes.stringType)), Regexp.class));
  }
}
